/*
Copyright SecureKey Technologies Inc. All Rights Reserved.

SPDX-License-Identifier: Apache-2.0
*/
package data

import "git.cloud.inspur.com/ichain/ichain-sdk-go/pkg/client/chain"

const (
	pvk137gm = `
-----BEGIN PRIVATE KEY-----
MIGTAgEAMBMGByqGSM49AgEGCCqBHM9VAYItBHkwdwIBAQQgatOT4BaYJTt9xTk2
7ywYwbEzUZ+Dp4pLf47bgUpWp6egCgYIKoEcz1UBgi2hRANCAASJfE4aAJ1QjvT4
Ghqj24Pl2L22fS2GCIwbaY878KWMSXvHN4r3IU6CBwESUNCo9HCreqX198OvionT
GR33ob4D
-----END PRIVATE KEY-----
`

	cert137gm = `
-----BEGIN CERTIFICATE-----
MIICTDCCAfKgAwIBAgIRAID5L45y35E1P5EyrndD+fYwCgYIKoEcz1UBg3UwgYYx
CzAJBgNVBAYTAkNOMREwDwYDVQQIEwhTaGFuZG9uZzEOMAwGA1UEBxMFSmluYW4x
CTAHBgNVBAkTADEJMAcGA1UEERMAMQ4wDAYDVQQKEwVPcmcwMTEPMA0GA1UECxMG
aWNoYWluMR0wGwYDVQQDExRjYS5vcmcwMS5kc3AuaWJwLmNvbTAeFw0yMzExMTAw
MjAwMDBaFw0zMzExMDcwMjAwMDBaMHkxCzAJBgNVBAYTAkNOMREwDwYDVQQIEwhT
aGFuZG9uZzEOMAwGA1UEBxMFSmluYW4xCTAHBgNVBAkTADEJMAcGA1UEERMAMQ8w
DQYDVQQLEwZpY2hhaW4xIDAeBgNVBAMMF3VzZXIxQG9yZzAxLmRzcC5pYnAuY29t
MFkwEwYHKoZIzj0CAQYIKoEcz1UBgi0DQgAEiXxOGgCdUI70+Boao9uD5di9tn0t
hgiMG2mPO/CljEl7xzeK9yFOggcBElDQqPRwq3ql9ffDr4qJ0xkd96G+A6NNMEsw
DgYDVR0PAQH/BAQDAgeAMAwGA1UdEwEB/wQCMAAwKwYDVR0jBCQwIoAgDg0G/ofI
TjdD9HPNGFK3D9xvMEN3yg2BLDGZkq3I0ZIw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LT
GYi7PfgBAjOxu0mF9QIgAKAT/H2q8MXTrt+hk4I1JrcwXz+dbgKwGEDvVrHySHk=
-----END CERTIFICATE-----
`
)

func Baas137GM() *BaasEnv {
	return &BaasEnv{
		orgName:        "org01",
		iamId:          "org01",
		chainId:        "dsp-chain",
		cert:           cert137gm,
		pvk:            pvk137gm,
		adminCert:      cert137AdminGM,
		adminPvk:       key137AdminGM,
		loglevel:       "debug",
		inodeList:      []string{"inode0.org01.dsp.ibp.com"},
		inodeUrls:      []string{"grpcs://10.110.8.137:8526"},
		inodeCerts:     []string{inodeTlsGM},
		consenserList:  []string{"consenser1.dsp.ibp.com"},
		consenserUrls:  []string{"grpcs://10.110.8.137:7520"},
		consenserCerts: []string{consenserTlsGM},
		ccInvoke: []chain.Request{
			{
				ContractID: "apilog-contract",
				Fcn:        "query",
				Args:       [][]byte{[]byte("key1")},
			},
		},
		cryptoType: "GM",

		tlsCert: tlsCert,
		tlsKey:  tlsKey,
	}
}
